<script setup lang="ts">
  // darkTheme
  import { zhCN, dateZhCN } from 'naive-ui';
  import antdZhCN from 'ant-design-vue/es/locale/zh_CN';
  import { computed } from 'vue';
  import AppProvider from '@/components/AppProvider';

  const getThemeOverrides = computed(() => {
    return {
      common: {
        primaryColor: '#2d8cf0',
        primaryColorHover: '#3c9bff',
        primaryColorPressed: '#3c9bff',
      },
      LoadingBar: {
        colorLoading: '#2d8cf0',
      },
    };
  });
</script>

<template>
  <a-config-provider :locale="antdZhCN">
    <n-config-provider :locale="zhCN" :theme-overrides="getThemeOverrides" :date-locale="dateZhCN">
      <AppProvider>
        <RouterView />
      </AppProvider>
    </n-config-provider>
  </a-config-provider>
</template>

<style lang="less">
  @import 'styles/index.less';
</style>
